//*********************************************************
//
//    Copyright (c) Microsoft. All rights reserved.
//    This code is licensed under the Apache License, Version 2.0.
//    THIS CODE IS PROVIDED *AS IS* WITHOUT WARRANTY OF
//    ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING ANY
//    IMPLIED WARRANTIES OF FITNESS FOR A PARTICULAR
//    PURPOSE, MERCHANTABILITY, OR NON-INFRINGEMENT.
//
//*********************************************************

namespace Microsoft.Research.eResearch.Blackboard.Interfaces
{
    using System;
    using System.Collections.ObjectModel;

    /// <summary>
    /// Represents a storage service that can keep track of a list 
    /// of current publishers.
    /// </summary>
    public interface IPublisherStore
    {
        /// <summary>
        /// Registers the specified return address into the list of current publishers.
        /// </summary>
        /// <param name="returnAddress">The return address of the new publisher.</param>
        void Register(Uri returnAddress);

        /// <summary>
        /// Unregisters the specified return address from the list of current publishers.
        /// </summary>
        /// <param name="returnAddress">The return address to unregister.</param>
        void Unregister(Uri returnAddress);

        /// <summary>
        /// Gets the list of current publishers.
        /// </summary>
        /// <returns>A collection of current publishers.</returns>
        ReadOnlyCollection<Uri> GetCurrentPublisherList();
    }
}
